package com.sw.fastdev.utils;

import android.app.Activity;

import com.sw.fastdev.global.MyApplication;


/**
 * 常用工具类
 */
public class CommonUtils {
	public static void runOnUIThread(Runnable runnable){
		MyApplication.getMainHandler().post(runnable);
	}
	public static void runOnUIThread(Activity activity, Runnable runnable){
		activity.runOnUiThread(runnable);
		}

	public static float getDimens(int resId){
		return MyApplication.getContext().getResources().getDimension(resId);
	}
	
	public static String getString(int resId){
		return MyApplication.getContext().getResources().getString(resId);
	}
}
